// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import axios from 'axios'
import Mint from 'mint-ui';
import echarts from 'echarts'
require('echarts/theme/hengyi');

import '../static/css/all.css'
import 'mint-ui/lib/style.css'
import '../static/mui/css/mui.css'
import '../static/icon/alicon/iconfont.css'
import { getsessionstorage } from "@/components/js/Localstorage.js"

Vue.use(Mint);
Vue.prototype.$http = axios
Vue.prototype.$echarts = echarts 
Vue.config.productionTip = false

axios.interceptors.request.use(
	config => {	
		var token = getsessionstorage("authorization");
		if(token) {
			config.headers.Authorization = token;
		}else{
			config.headers.Authorization = "666";
		}
		return config
	},
	error => {
		return Promise.reject(error)
	});

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  components: { App },
  template: '<App/>'
})


